package routers

import (
	"github.com/gin-gonic/gin"
)

//func SetRouter(c *gin.Context) {
func SetRouter(c *gin.Engine) {
	//r := gin.Default()
	//设置最大内存，默认32M
	//r.MaxMultipartMemory = 8 << 20  //设置限制最大为8M
	//r.GET("/", func(c *gin.Context) {
	//	//c.String(http.StatusOK, "hello word")
	//	c.JSON(200, gin.H{
	//		"message": "hello world",
	//	})
	//})
	//c.GET("/", control.HelloHandler)
	//c.GET("/p", control.GetUrlQueryHandler)
	//c.GET("/p/:id/:name/", control.GetUrlParamHandler)
	//c.POST("/file", control.UploadFileHandler)
	//c.POST("/files", control.MultiFileHandler)
	//c.POST("/json", control.ParseJson)
	//路由分组
	// 路由组1 ，处理GET请求
	//v1 := r.Group("/v1")
	//// {} 是书写规范
	//{
	//	v1.GET("/login", control.Login)
	//	v1.GET("submit", control.Submit)
	//}
	//v2 := r.Group("/v2")
	//{
	//	v2.POST("/login", control.Login)
	//	v2.POST("/submit", control.Submit)
	//}
	//return r
}
